package com.example.demo.domain;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.Map;

@JsonIgnoreProperties(ignoreUnknown = true)
public class WorkflowRequest {

    // Dify API 期望所有的输入都在一个 'inputs' 对象下
    // 这里用 Map<String, FileInput> 来灵活映射 'request', 'review' 等输入名称
    private Map<String, FileInput> inputs;

    @JsonProperty("response_mode") // 字段名匹配：response_mode
    private String responseMode;

    private String user;

    // Getters and Setters
    public Map<String, FileInput> getInputs() {
        return inputs;
    }

    public void setInputs(Map<String, FileInput> inputs) {
        this.inputs = inputs;
    }

    public String getResponseMode() {
        return responseMode;
    }

    public void setResponseMode(String responseMode) {
        this.responseMode = responseMode;
    }

    public String getUser() {
        return user;
    }

    public void setUser(String user) {
        this.user = user;
    }

    @Override
    public String toString() {
        return "WorkflowRequest{" +
                "inputs=" + inputs +
                ", responseMode='" + responseMode + '\'' +
                ", user='" + user + '\'' +
                '}';
    }
}

